﻿<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="ManterEspecificacao.aspx.cs" Inherits="ManterEspecificacao" Title="Untitled Page" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <div class="demoheading" style="width:400px">Manter Especificação</div>
     <asp:Panel ID="Panel2" runat="server" CssClass="collapsePanelHeader" 
        Height="20px" Width="400px">
                    <div style=" padding: 5px; cursor: pointer; vertical-align: middle; width: 391px;">
                        <div style="float: left;">Consultar Especificação</div>
                    </div>
                </asp:Panel>
    <div style="width:400px">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>        
            <asp:GridView ID="GridView1" runat="server" AllowPaging="True" 
                AutoGenerateColumns="False" BackColor="White" BorderColor="#DEDFDE" 
                BorderStyle="None" BorderWidth="1px" CellPadding="4" 
                DataSourceID="ObjectDataSource1" ForeColor="Black" GridLines="Vertical">
                <FooterStyle BackColor="#CCCC99" />
                <RowStyle BackColor="#F7F7DE" />
                <Columns>
                    <asp:BoundField DataField="Codigo" HeaderText="Codigo" 
                        SortExpression="Codigo" />
                    <asp:BoundField DataField="Tipo" HeaderText="Tipo" SortExpression="Tipo" />
                    <asp:BoundField DataField="Largura" HeaderText="Largura" 
                        SortExpression="Largura" />
                    <asp:BoundField DataField="Altura" HeaderText="Altura" 
                        SortExpression="Altura" />
                    <asp:BoundField DataField="Bitrate" HeaderText="Bitrate" 
                        SortExpression="Bitrate" />
                    <asp:TemplateField HeaderText="Atualizar/Remover">
                        <ItemTemplate>
                            <asp:LinkButton ID="LinkButton1" runat="server" onclick="LinkButton1_Click">Atualizar</asp:LinkButton>
                            &nbsp;
                            <asp:LinkButton ID="LinkButton2" runat="server" onclick="LinkButton2_Click">Remover</asp:LinkButton>
                        </ItemTemplate>
                    </asp:TemplateField>
                </Columns>
                <PagerStyle BackColor="#F7F7DE" ForeColor="Black" HorizontalAlign="Right" />
                <SelectedRowStyle BackColor="#CE5D5A" Font-Bold="True" ForeColor="White" />
                <HeaderStyle BackColor="#6B696B" Font-Bold="True" ForeColor="White" />
                <AlternatingRowStyle BackColor="White" />
            </asp:GridView>
          </ContentTemplate>  
             </asp:UpdatePanel>
        </div>     
        <asp:ObjectDataSource ID="ObjectDataSource1" runat="server" 
        DataObjectTypeName="Negocios.Especificacao" DeleteMethod="Excluir" 
        InsertMethod="Insere" OldValuesParameterFormatString="original_{0}" 
        SelectMethod="ConsultaTodos" TypeName="Negocios.EspecificacaoBLL" 
        UpdateMethod="Consultar">
            <UpdateParameters>
                <asp:Parameter Name="codigo" Type="Int32" />
            </UpdateParameters>
    </asp:ObjectDataSource>
        <br />
         <asp:Panel ID="Panel1" runat="server" CssClass="collapsePanelHeader" 
        Height="20px" Width="400px">
                    <div style=" padding: 5px; cursor: pointer; vertical-align: middle; width: 392px;">
                        <div style="float: left;"></div>
                    </div>
                </asp:Panel>
        <div style="width:400px">
        <asp:UpdatePanel ID="UpdatePanel2" runat="server">
        <ContentTemplate>
            <table style="width: 400px" class="divDados">
                <tr class="divOID">
                    <td style="width: 93px">
                        <asp:Label ID="Label1" runat="server" Text="Código" Enabled="False"></asp:Label>
                    </td>
                    <td>
                        <asp:TextBox ID="tbCodigo" runat="server"></asp:TextBox>
                        <asp:Button ID="btNovo" runat="server" onclick="Novo_Click" Text="Novo" />
                    </td>
                </tr>
                <tr>
                    <td style="width: 93px">
                        <asp:Label ID="Label2" runat="server" Text="Tipo" Enabled="False"></asp:Label>
                    </td>
                    <td>
                        <asp:DropDownList ID="ddlTipo" runat="server" Enabled="False">
                            <asp:ListItem Value="0">Selecione o tipo</asp:ListItem>
                            <asp:ListItem Value="1">imagem/Vídeo</asp:ListItem>
                            <asp:ListItem Value="2">Áudio</asp:ListItem>
                        </asp:DropDownList>
                    </td>
                </tr>
                <tr>
                    <td style="width: 93px">
                        <asp:Label ID="Label3" runat="server" Text="Largura" Enabled="False"></asp:Label>
                    </td>
                    <td>
                        <asp:TextBox ID="tbLargura" runat="server" Enabled="False"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td style="width: 93px">
                        <asp:Label ID="Label4" runat="server" Text="Altura"></asp:Label>
                    </td>
                    <td>
                        <asp:TextBox ID="TBAltura" runat="server" Enabled="False"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td style="width: 93px">
                        <asp:Label ID="Label5" runat="server" Text="Bitrate"></asp:Label>
                    </td>
                    <td>
                        <asp:TextBox ID="TBBitrate" runat="server" Enabled="False"></asp:TextBox>
                        <asp:Label ID="Label6" runat="server" Text="Kbps" Enabled="False"></asp:Label>
                    </td>
                </tr>
                <tr>
                    <td align="center" colspan="2">
                        <asp:Button ID="btGravar" runat="server" Text="Gravar" Enabled="False" 
                            onclick="btGravar_Click" style="height: 26px" />
                        <asp:Button ID="btCancelar" runat="server" Text="Cancelar" Enabled="False" 
                            onclick="btCancelar_Click" />
                    </td>
                </tr>
            </table>
             <asp:Label ID="lbErro" runat="server"></asp:Label>
          </ContentTemplate>  
             </asp:UpdatePanel>
        </div>
   
</asp:Content>

